1. Field of the Invention
The present invention relates to a technology for compressing the dynamic range of an input image.
2. Description of the Related Art
An image enhancement method called Center/Surround Retinex (hereinafter, “Retinex method”), modeled after human vision, is generally used to compress the dynamic range of an input image.
For example, Japanese Patent Laid-Open Publication No. 200-511315 discloses a technique concerning the Retinex method, in which the dynamic range of the entire image is compressed by suppressing low-frequency components extracted from the input image with a low-pass filter.
According to the Retinex method, a pixel value O(x, y) of an output image is represented as follows:O(x,y)=log(I(x,y))−log(LPF(I(x,y)))where I(x, y) is a pixel value of an input image, and LPF(I(x, y)) is a pixel value of the low-frequency component extracted by a low-pass filter.
The Retinex method produces excellent results on dynamic range compression in low-frequency areas where brightness changes gradually. However, overshoot or undershoot occurs in high-frequency areas (such as edge areas) where there is a sharp change in the brightness, resulting in degradation in the quality of an output image.
Specifically, in the Retinex method, a smoothed pixel value (low-frequency components) is calculated by low-pass filtering pixels around a pixel that is to be corrected (hereinafter, “correction pixel”), and the smoothed pixel value is approximated to the center value of the dynamic range (suppression of low-frequency components). In addition, a relative value (high-frequency components) of the smoothed pixel value and the pixel value of the correction pixel is enhanced (enhancement of high-frequency components). The suppressed low-frequency components and the enhanced high-frequency components are then combined to produce an output image. In the edge portion where there is a sharp change in the brightness, the relative value of a smoothed image (composed of smoothed pixels) and an input image increases sharply, which compromises the quality of the output image.
Thus, there is a need of a technology capable of preventing overshoot and undershoot at edge portions while achieving dynamic range compression of low-frequency components.